package com.meituan.sdk.model.pms.coupon.publishChannelCoupon;

import com.meituan.sdk.annotations.ApiMeta;
import java.util.List;
import com.google.gson.reflect.TypeToken;
import java.lang.reflect.Type;
import com.meituan.sdk.internal.utils.JsonUtil;
import com.google.gson.annotations.SerializedName;
import javax.validation.constraints.NotNull;
import com.meituan.sdk.MeituanResponse;
import com.meituan.sdk.MeituanRequest;
import javax.validation.constraints.NotEmpty;

/**
* 发布渠道优惠券
* This file was automatically generated.
*/
@ApiMeta(
    path = "/pms/coupon/publishChannelCoupon",
    businessId = 57,
    apiVersion = "10011",
    apiName = "publish_channel_coupon",
    needAuth = true
)
public class PublishChannelCouponRequest implements MeituanRequest<PublishChannelCouponResponse> {
    /**
    * <p data-diff-id="ct-diff-id-25446d54-1171-499c-8937-288098541c46">模版id</p>
    */
    @NotEmpty(message = "templateId不能为空")
    @SerializedName("templateId")
    private List<Long> templateId;
    /**
    * <p data-diff-id="ct-diff-id-ccf4d64b-e17c-47d2-a62a-2bf0d59bd3a4">会员id</p>
    */
    @NotEmpty(message = "memberId不能为空")
    @SerializedName("memberId")
    private List<Long> memberId;
    /**
    * <p data-diff-id="ct-diff-id-78de4f12-9528-4eab-b8fa-c8c5757edb11">数量</p>
    */
    @NotNull(message = "count不能为空")
    @SerializedName("count")
    private Integer count;

    public List<Long> getTemplateId() {
        return templateId;
    }
    public void setTemplateId(List<Long> templateId) {
        this.templateId = templateId;
    }
    public List<Long> getMemberId() {
        return memberId;
    }
    public void setMemberId(List<Long> memberId) {
        this.memberId = memberId;
    }
    public Integer getCount() {
        return count;
    }
    public void setCount(Integer count) {
        this.count = count;
    }


    @Override
    public MeituanResponse<PublishChannelCouponResponse> deserializeResponse(String response) {
        Type type = new TypeToken<MeituanResponse<PublishChannelCouponResponse>>(){}.getType();
        return JsonUtil.fromJson(response, type);
    }
    @Override
    public String serializeToJson() {
        return JsonUtil.toJson(this);
    }


    @Override
    public String toString() {
        return "PublishChannelCouponRequest{" + "templateId=" + templateId + "," + "memberId=" + memberId + "," + "count=" + count + "}";
    }
}
